import {RICH_TEXT_CONTENT} from "../action-types";

const initialState = {
    editorContent: ''
};
export const richTextEditorReducer = (state = initialState, action) => {
    const tempState = {
        [RICH_TEXT_CONTENT]: state.editorContent
    };
    switch (action.type) {
        case RICH_TEXT_CONTENT:
            tempState[RICH_TEXT_CONTENT] = action.editorContent;
            return tempState;
        default:
            return state
    }
};